<?php

namespace App\Http\Validators;

class ValidatorFactory
{
    private $validator;

    public function __construct(ValidatorInterface $validatorObj)
    {
        $this->validator = $validatorObj;
    }

    public function factory($data)
    {
        return $this->validator->excute($data);
    }
}